Automation multiplies whatever process you point it at. Fix the process manually first, then automate the version that works.